package ynu.edu.online_course.service;

import jakarta.transaction.Transactional;
import ynu.edu.online_course.entity.Banned;
import ynu.edu.online_course.entity.User;

public interface UserService {
    Long login(String username, String password);
    Boolean register(User user);
    void updateUserInfo(User user);
    void deleteUser(Long userId);
    void freezeUser(User userId, User operatedBy);
    Long getUserIdByTelephone(String telephone);
    void updatePassword(Long userId, String newPassword);
    void updateTelephone(Long userId, String newTelephone);
    @Transactional
    void banUser(Banned banned);
    boolean isAdmin(Long userId);
}
